DT1 Tooler Help File

DT1 Tooler is a Liberty BASIC application that is simply a GUI wrapper for DT1 Tools (which are C programs without a real GUI and must be run from BAT files). DT1 Tooler attempts to bridge the gap and make it easier to handle DT1s (it's up to you to learn how to edit them!).

SETUP

You will need the following files/folders to use DT1 Tooler effectively:

Folder 1:
* Paul Siramy's DT1 Tools:
	DT1Debug.exe
	DT1Extr.exe
	DT1Make.exe
	palettes folder (d2pal) if you're using version 1 of DT1Debug
  (If you use versions with different names, just rename them to the above.)
* Sir Xavius DT1 Tooler.exe (and its INI) and its required libraries and graphics.
* Template files for creating PCXs and INI (must be named "template.pcx" and "template.ini")
* The Help file "Tooler Help.txt"

Folder X (but not the same as above):
* Any DT1s you wish to view or edit
* Any PCXs and their accompanying INIs you wish to compile

***It's highly recommended that you keep all DT1 projects in separate subfolders as they can easily become a jumbled mess of files when combined.***

USE

Run DT1 Tooler. There are no command lines to use, and Tooler keeps up with previous sessions by creating/calling from Tooler.ini. (If this file is not at the root level with the application when it starts up, it generates a new one when exiting Tooler.)

You must set up your Preferences first, as Tooler requires certain paths to work. Click on the Options button, and set all the data in the ensuing dialog. 
	* The Default Directory is the folder to which the DT1 files should reside and editable files will be placed. This is your work folder, and can be created from the Find dialog.
	* You also need to enter the paths to the graphics editor and text editor you want to use.
	* You can also have the application confirm your exit if you want.

Normally the first thing you want to do is load a specific DT1 (only one can be done at a time). Click on the top Search icon to browse for a DT1 to use, or type the FULL PATH in the first field. This will be the current working DT1.

"""""""""" VIEWING THE DT1 """""""""""
To view the DT1 (both graphics and data), click on View. This will create a temporary BAT to open DT1Debug, and you can use as normal from here. When you're done, hit the Esc key.
NOTE: There are 3 important functional differences between the original DT1Debug (which we'll call DT1 Debug_0) and the revised version from Feb 2011 (which we'll call DT1Debug_1).
   1.	If you are using the DT1Debug_0 (ca. 2002) as your viewer, you must also have the D2pal folder at the same level as DT1Debug.
   2.	When DT1Debug_0 starts up, it will be in full screen, and your monitor may not be able to handle the low resolution. Just tap the + key on the number pad once (or possibly twice) to increase to a more compatible resolution.
   3.	Due to the syntax change in the command line parameter, DT1Debug_0 will not apply the palette you choose when viewing the given DT1.
Because of these differences, your best bet is to get the version the author updated in Feb 2011.

""""""""""" EXTRACTING THE EDITABLE FILES """"""""""""
To extract the graphics (to PCX) and data (to INI) of the DT1, click on the Extract button. Again a temporary BAT file is created and run, except that PCXs and an INI file are created to account for all the tiles in the DT1. These are placed in the Default Directory. 
When there is nothing in the DT1 field, this button reads "Create" and will instead create a new set of PCX/INI files ready for editing. This does so by copying the template files in you DT1 Tools folder, so those must be present. You'll be prompted to enter a name for the new folder and its files, and the new files will be created based on internal data structures, one for each type of pcx (static and animated floors, and ascending and descending walls). The DT1 field is also filled with the new name of the potential DT1.

""""""""""" EDITING THE GRAPHICS AND DATA """"""""""""
From here you can use Tooler to launch your graphics/text editor for the specific files. Click on Edit and if the correct files are found, you will prompted as to which one you wish to edit. After selecting, Tooler will create a temporary batch file and run your editor from there (BASIC has a few problems with long pathnames, so creating a BAT works around the limitation). 
When you're done editing you do not have to close the editor unless you know you won't be doing any more editing. But be sure to save the edited files to bring in the changes when you compile.

""""""""""" COMPILING THE DT1 """"""""""""
When you're ready to compile the PCXs and INI into a DT1, click on Compile and if all goes well, the DT1 will be created. (If a DT1 with that name already exists in the Default Directory, you will be prompted if you wish to overwrite the old DT1; if not, the new DT1 will have the prefix "NEW_" in the name.)

Before you do anything else, make sure you take a look at your creation and check the data for errors either in the graphics or settings. (If you did not overwrite the DT1, you must add the "NEW_" prefix to the name in the DT1 field at the top.)